From 8ae2b0d5dd68b535aa81fb4ba6e3657d1bfe2b12 Mon Sep 17 00:00:00 2001 From: Simon Shi Date: Sat, 9 Mar 2019 13:01:55 +0800 Subject: twinstall: Force variable type Force the usage of variable type since it is different on the 32-bit devices. Use this commit to avoid the problem. bugs: bootable/recovery/twinstall.cpp:201:67: error: format specifies type 'size_t' (aka 'unsigned int') but the argument has type 'long long' [-Werror,-Wformat] LOGINFO("has_legacy_properties: mmap (size=%zu) failed: %s!\n", finfo.st_size, strerror(errno)); ~~~ ^~~~~~~~~~~~~ %lld Change-Id: Ie0c51a90490e0c069fff33884a9431a97361f5c6 --- twinstall.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/twinstall.cpp b/twinstall.cpp index f451ca551..fa6b8594e 100644 --- a/twinstall.cpp +++ b/twinstall.cpp @@ -198,7 +198,7 @@ static bool update_binary_has_legacy_properties(const char *binary) { void *data = mmap(NULL, finfo.st_size, PROT_READ, MAP_PRIVATE, fd, 0); if (data == MAP_FAILED) { - LOGINFO("has_legacy_properties: mmap (size=%zu) failed: %s!\n", finfo.st_size, strerror(errno)); + LOGINFO("has_legacy_properties: mmap (size=%zu) failed: %s!\n", (size_t)finfo.st_size, strerror(errno)); } else { if (memmem(data, finfo.st_size, str_to_match, len_to_match)) { LOGINFO("has_legacy_properties: Found legacy property match!\n"); -- cgit v1.2.3